package com.xuzimian.alibaba.coding.guideline.zimian.programming.protocol;


public class PrizesActivity {

    static volatile int prizesCount = 1;

    public static void getPrize() {
        if (prizesCount > 0) {
            int newPrizesCount = prizesCount - 1;
            prizesCount = newPrizesCount;
            System.out.println("取出奖品" + prizesCount);
        }

    }
}
